# Q-Project
# Urls Module
# Copyright (C) 2010 by Andres Rocha, Miguel Ordo/ez, Edgar Sotelo
# 
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
# 
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# GNU General Public License for more details.
# 
# You should have received a copy of the GNU General Public License
# along with this program.  If not, see <http://www.gnu.org/licenses/>.


from django.conf.urls.defaults import *
import os

SITE_ROOT = os.path.realpath(os.path.dirname(__file__))

# Uncomment the next two lines to enable the admin:
from django.contrib import admin
admin.autodiscover()

urlpatterns = patterns('',
# Example:
# (r'^Q/', include('Q.foo.urls')),

# Uncomment the admin/doc line below and add 'django.contrib.admindocs' 
# to INSTALLED_APPS to enable admin documentation:
# (r'^admin/doc/', include('django.contrib.admindocs.urls')),

# Uncomment the next line to enable the admin:
    (r'^admin/', include(admin.site.urls)),
    (r'Q/$','Q.QApp.views.main'),
    (r'Q/register/$', 'Q.QApp.views.register'),
    (r'Q/login/$','Q.QApp.views.session'),
    (r'Q/logout/$','Q.QApp.views.logout'),
    (r'Q/editprofile/$','Q.QApp.views.profile'),
    (r'Q/saveprofile/$','Q.QApp.views.profile_save'),
    (r'Q/topics/$','Q.QApp.views.topic'),
    (r'Q/savetopic/$','Q.QApp.views.topic_save'),
    (r'Q/savequestion/$','Q.QApp.views.question_save'),
    (r'Q/replyquestion/$','Q.QApp.views.reply'),
    (r'Q/reply_save/$', 'Q.QApp.views.reply_save'),
    (r'^static/(?P<path>.*)$','django.views.static.serve',{'document_root': os.path.join(SITE_ROOT,'static')}),
    )